import { formProps, formItemProps } from 'ant-design-vue/es/form';

export const SchemaFormProps = {
  ...formProps(),
  schemas: {
    type: Array<any>,
    default: () => [],
  },
  type: String,
  span: Number,
};

export const SchemaFormItemProps = {
  ...formItemProps(),
  component: {
    type: String,
    required: true,
  },
  dataIndex: {
    type: String,
    required: true,
    default: '',
  },
  formState: {
    type: Object,
    default: () => {},
  },
  vIf: {
    type: Function,
    default: null,
  },
  span: {
    type: Number,
    default: 24,
  },
  hide: {
    type: Boolean,
    default: false,
  },
  vShow: {
    type: Boolean,
    default: true,
  },
  componentProps: {
    type: Object,
    default: () => {},
  },
  mode: {
    type: String,
    default: '',
  },
};
